1. Field of the Present Invention
The present invention generally relates to the field of microprocessor based computer and more particularly to a method and system for booting a computer with one of multiple boot images.
2. History of Related Art
Computer systems generally require some manner of boot procedure to achieve a functional state after a system reset, a system wake up, or a power-on event. The boot procedure typically includes executing a boot sequence stored on a nonvolatile memory of the system. The boot sequence is responsible for loading a boot image into system memory. Historically, a computer system""s boot device was suitable for loading only a single boot image. With a conventionally designed machine, an end user who wishes to load a different boot image than the boot image stored on the system""s boot device is required to obtain an second boot or reprogram the existing boot device, thereby losing the original boot image in the process. Manufacturers of conventionally designed systems must stock multiple types of boot devices to meet the various needs of their customers. Customers requiring a first type of boot image will require a first boot device while customers requiring a second type of boot image will require a second boot device thereby creating potential manufacturing concerns including order tracking and inventory management for the manufacturer. Moreover, the differing requirements of various customers prevents the manufacturer from being able to build, stock, and sell a single machine that can meet the needs of all of its customers (assuming that, aside from the boot image, the different customers have the same computing requirements). In addition, the number of users who require the option of being able to boot from multiple boot images is increasing. Such users face currently face the formidable task of reprogramming or physically replacing the boot device in their systems each time they need to switch images. Accordingly, for a number of reasons, it is would be highly desirable to offer a system capable of easily switching between multiple boot images.
Broadly speaking the present invention contemplates a computer system and an accompanying boot code storage device. According to the invention, the computer system includes a processor, a system memory, and the boot code storage device. The system memory is connected to the processor and is suitable for storing processor data and instructions. The boot code storage device includes an image selection indicator for indicating which of multiple boot code images are to be loaded into the system memory. The computer system further includes means for initiating a boot sequence stored on the boot code storage device. The boot sequence selects from first and second boot images based upon the state of the image selection indicator and loads the selected image into the system memory in response to a boot event. In one embodiment, the image selection indicator is in an initial state until the boot code sequence successfully loads one of the boot images. The image selection indicator is set to a value indicative of the loaded image when one of the boot images is successfully loaded. The boot code storage sequence attempts, in the preferred embodiment, to load a previously loaded boot image when the system detects a setting of the image selection indicator indicative of a previously loaded boot image. In other words, the system has a preference to load a previously loaded boot image. In the preferred embodiment, the boot code sequence responds to a specified user input sequence by presenting the user with a configuration screen suitable for altering the value of the image selection indicator such that the user may alter the boot image that will be loaded during a subsequent execution of the boot sequence. In one embodiment, the first boot image is a BIOS based boot image and the second image is a network based (non-BIOS) boot image. The boot code storage device is preferably a flash memory device.
The invention still further contemplates a method of booting a computer system. A boot code sequence responsive to a boot event is initiated and the state of an image selection indicator determined. In response to detecting an initial state of the image selection indicator, an attempt is made to load, in sequential order, one of a set of boot images until one of the boot images loads successfully. When one of the boot images loads successfully, the image selection indicator is set to a value indicative of the successfully loaded image. In response to detecting a state of the image selection indicator indicative of a previously loaded boot image, the previously loaded boot image is loaded into system memory. The method further includes displaying a configuration screen suitable for altering the state of the image selection indicator when a specified user input sequence is detected during execution of the boot code sequence. The process of altering the state of the image selection indicator comprises, in one embodiment, programming a flash memory device on which the image selection indicator is located. The boot event may be comprised of a local boot event such as a resetting of the computer system or a network based boot event.